<template>
  <div class="order">
        <van-nav-bar
  title="我的订单"
  left-text="返回"
  left-arrow
  @click-left="onClickLeft"
/>
   
    <van-tabs v-model="active">
  <van-tab title="全部">
<div class="box2">
      <div class="title">
        <div class="name">纯手工饺子(凤城九路店)</div>
        <div class="flag">已送达</div>
      </div>
      <div class="img">
        <div class="left">
          <img src="../../assets/logo.png" alt="" />
        </div>
        <div class="right">
          <div class="price">¥17.2</div>
          <div class="count">共2件</div>
        </div>
      </div>
       <div class="btn">再来一单</div>
    </div>
    
  </van-tab>
  <van-tab title="待消费"></van-tab>
  <van-tab title="待评价"></van-tab>
  <van-tab title="退款"></van-tab>
</van-tabs>
    
  </div>
</template>

<script>
import Vue from 'vue';
import { NavBar } from 'vant';
import { Toast } from 'vant';
import { Tab, Tabs } from 'vant';

Vue.use(Tab);
Vue.use(Tabs);
Vue.use(Toast);
Vue.use(NavBar);
export default {
    data(){
        return{
             active: 0,
        }
    },
      methods: {
    onClickLeft() {
      Toast('返回');
      this.$router.go(-1)
    },
  },
};
</script>

<style lang="scss" scoped>
.order {
//   margin-top: 2.7778rem;
  height: 100%;
 background-color: rgb(248, 248, 248);

  .box2 {
    margin-top: 1.1111rem;
    background-color: #fff;
    border-radius: 0.8333rem;
    padding: .5556rem;
    margin-bottom: .4444rem;
   padding: .2778rem 1.1111rem;
  }
  .title {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .name {
    font-weight: bold;
  }
  .flag {
    color: #ccc;
  }
  .img {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: .5556rem;
    margin-top: .8333rem;
  }
  .left {
    width: 5.5556rem;
    display: flex;
    img {
      width: 100%;
      display: block;
      margin-right: 0.2778rem;
      border-radius: 0.2778rem;
    }
  }
  .count {
    color: #ccc;
    font-size: 0.8333rem;
  }
  .btn{
    font-size: .8333rem;
    color:rgb(27, 176, 235);
    border:1px solid rgb(27, 176, 235);
    border-radius: 1.3889rem;
    padding: .5556rem .8333rem;
    margin-left: 11.6667rem;
    text-align: center;
  }
}
</style>